package cn.ly.spring4.aop;

import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;


public class MainTest {
	
	@Test
	public void testloginAspect() {
		ApplicationContext ac = new ClassPathXmlApplicationContext("bean.xml");
		LoginAction login = (LoginAction)ac.getBean(LoginAction.class);
		login.login("t1", new Object());
		login.login("root", "root");
		login.logout("root");
	}
}
